package com.woniuxy.happylife.service.impl;

import com.woniuxy.happylife.dao.CommentsDao;
import com.woniuxy.happylife.entity.MallRemark;
import com.woniuxy.happylife.service.CommentsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @Author:roger
 * @Date:2022/2/19 16:22:07
 * @Description:
 */
@Service
public class CommentsServiceImpl implements CommentsService {
    @Autowired
    CommentsDao commentsDao;
    //发布评论
    @Override
    public Integer publish(MallRemark mallRemark) {
        return commentsDao.publish(mallRemark);
    }

    @Override
    public List<MallRemark> getBygid(int gid) {
        return commentsDao.getBygid(gid);
    }

    @Override
    public Integer getNumsBygid(int gid) {
        return commentsDao.getNumsBygid(gid);
    }

}
